﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;

namespace PwjCy.Lite.Cache.Imp
{
    public class CacheService : ICacheService
    {
        private const string CacheKeyPrefix = "Pwjcy_Lite_CacheService";
        private System.Collections.Hashtable cacheHashTable = new System.Collections.Hashtable();
        public void AddCache<T>(T obj, string key)
        {
            cacheHashTable[CacheKeyPrefix + key] = obj;
        }
        public T GetCache<T>(string key)
        {
            return (T)cacheHashTable[CacheKeyPrefix + key];
        }
    }
}
